package javabase.schoolwork.day5_28;

import java.util.Arrays;

/**
 * @author fance
 * @date 2018/5/29 11:30
 */
public class SortedArray extends Array {
    public SortedArray() {
    }

    public SortedArray(int init_size) {
        super(init_size);
    }
    public void sort() {
        Arrays.sort(elementData,0,foot);
    }

    public static void main(String[] args) {
        SortedArray array = new SortedArray();
        for (int i = 20; i >= 0; i--) {
            array.add(i);
        }
        array.sort();
        System.out.println(array);
    }
}
